package com.app.model;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.annotation.JsonInclude;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.sql.Timestamp;
import java.time.LocalDateTime;

@Data
@AllArgsConstructor
@NoArgsConstructor
@TableName("lm_user")
@JsonInclude(JsonInclude.Include.NON_NULL)
public class UserModel {
    @TableId(value="id",type= IdType.AUTO)
    private Integer id;
    @TableField(exist = false)
    private Integer cityId;
    @TableField(exist = false)
    private Integer townId;
    private String remark;
    private Integer villageId;
    @TableField(exist = false)
    private String villageText;
    private String name;//真实姓名
    @TableField(exist = false)
    private String sexText;
    private Integer sex;
    private String phoneNumber;//电话
    private String avatar;//头像
    private Integer auditStatus;//1未实名2已实名3审核中4未通过
    @TableField(exist = false)
    private String auditStatusText;//1未实名2已实名3审核中4未通过
    private Integer status;//状态，默认1
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8") //后端注解格式化日期
    private Timestamp lastLoginTime;//最后登录时间
    private String lastLoginIp;//最后登录ip
    private String idCard;//身份证号
    private String  openId;//微信用户唯一标识
    private Integer integral;//用户积分额
    @TableField(exist = false)
    private Integer handleIntegral;//处理后积分
    private Timestamp createTime;
    private Timestamp updateTime;
    @TableField(exist = false)
    private Integer page;
    @TableField(exist = false)
    private Integer limit;
    @TableField(exist = false)
    private String keyword;
    @TableField(exist = false)
    private Integer ranking;
}
